package com.zgl.modules.goods.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.time.LocalDateTime;

@Data
@NoArgsConstructor
@AllArgsConstructor
@TableName("t_goods")
public class GoodsEntity implements Serializable {
    private static final long serialVersionUID = 1L;
    @TableId
    @ApiModelProperty(value = "id")
    private Integer id;
    @ApiModelProperty(value = "商品名称")
    private String goodsName;
    @ApiModelProperty(value = "商品价格")
    private String goodsPrice;
    @ApiModelProperty(value = "商品详情")
    private String goodsDetail;
    @ApiModelProperty(value = "图片")
    private Object goodsImg;
    @ApiModelProperty(value = "商品利率")
    private String goodsRate;
    @ApiModelProperty(value = "风险等级")
    private Integer riskLevel;
    @ApiModelProperty(value = "最低金额")
    private String limitPrice;
    @ApiModelProperty(value = "商品期限",required = true)
    private Integer goodsTerm;
    @TableField(value="create_time")
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime data;
}
